<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>首页</title>
 <script>
		function validateForm(){
        var x=document.forms["myform"]["total"].value;
        if (x==""){
        alert("爬取页面数未填写，请重新填写！");
        return false;
           }
        else if(x<=0 || x>100){
            alert("输入超出所许范围，请重新输入！");
            return false;
        }
        else if(x>0 && x<=100){
            return true;
        }
        else
        {
            alert("输入含有非法字符，请重新输入！");
            return false;
        }
        }
</script>
<style>
* {
  box-sizing: border-box;
}
 
body {
  font-family: Arial;
  padding: 10px;
  background: #f1f1f1;
}
 
/* 头部标题 */
.header {
  padding: 10px;
  text-align: center;
  background: white;
}
 
.header h1 {
  font-size: 50px;
}
 
/* 导航条 */
.topnav {
  overflow: hidden;
  background-color: #333;
}
 
/* 导航条链接 */
.topnav a {
  float: left;
  display: block;
  color: #f2f2f2;
  text-align: center;
  padding: 14px 16px;
  text-decoration: none;
}
 
/* 链接颜色修改 */
.topnav a:hover {
  background-color: #ddd;
  color: black;
}
 
/* 创建两列 */
/* Left column */
.leftcolumn {   
  float: left;
  width: 75%;
}
 
/* 右侧栏 */
.rightcolumn {
  float: left;
  width: 25%;
  background-color: #f1f1f1;
  padding-left: 20px;
}
 
/* 图像部分 */
.fakeimg {
  background-color: #aaa;
  width: 100%;
  padding: 20px;
}
 
/* 文章卡片效果 */
.card {
  background-color: white;
  padding: 20px;
  margin-top: 20px;
}
 
/* 列后面清除浮动 */
.row:after {
  content: "";
  display: table;
  clear: both;
}
 
/* 底部 */
.footer {
  padding: 20px;
  text-align: center;
  background: #ddd;
  margin-top: 20px;
}
 
/* 响应式布局 - 屏幕尺寸小于 800px 时，两列布局改为上下布局 */
@media screen and (max-width: 800px) {
  .leftcolumn, .rightcolumn {   
    width: 100%;
    padding: 0;
  }
}
 
/* 响应式布局 -屏幕尺寸小于 400px 时，导航等布局改为上下布局 */
@media screen and (max-width: 400px) {
  .topnav a {
    float: none;
    width: 100%;
  }
}
/* 按钮 */
.button {
    background-color: black;
    border: none;
    color: white;
    padding: 15px 32px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    margin: 4px 2px;
    cursor: pointer;
}
/* checkbox */
.checkbox {
	width: 20px;
	height: 20px;
	background: #333;
	margin: 20px 20px;
 
	border-radius: 50px;
	position: relative;
}
h1
{
	text-shadow: 3px 3px 3px black;
}
h3 {text-decoration:underline;}
input[type=text] {
  width: 100%;
  padding: 12px 20px;
  margin: 8px 0;
  box-sizing: border-box;
  border: none;
  background-color: black;
  color: white;
}
</style>
</head>
<body>

<div class="header">
  <h1 class="h1">互联网行业招聘信息聚合</h1>
</div>

<div class="topnav">
  <a href="#">&nbsp</a>
  <a href="#"></a>
  <a href="#"></a>
</div>

<div class="row">
  <div class="leftcolumn">
    <div class="card">
      <div>
        <form name="myform" id="form1" method="post" action="spider?code=1" >
            <table>
                <td>
                    <label>
                        <div><h2>爬取目标</h2></div>
                    </label>
                    <label>
                        <div>
                            <h3><input type="checkbox" name="web1" value="11" class="checkbox" checked="">前程无忧网</h3>
                        </div>
                    </label>
                    <label>
                        <div>
                            <h3><input type="checkbox" name="web2" value="12" class="checkbox" checked="">齐鲁人才网</h3>
                        </div>
                    </label>
                    <label>
                        <div>
                           <h3><input type="checkbox" name="web3" value="13" class="checkbox" checked="">猎聘网</h3>
                        </div>
                    </label>
                </td>
                <td>
                </td>
                <td>
                </td>
                <td>
                </td>
                <td>
                </td>
                </td>
                <td>
                </td>
                <td>
                </td>
                </td>
                <td>
                </td>
                <td>
                </td>
                </td>
                <td>
                </td>
                <td>
                </td>
                <td>
                </td>
                </td>
                <td>
                </td>
                <td>
                </td>
                <td>
                </td>
                <td>
                </td>
                </td>
                <td>
                </td>
                <td>
                </td>
                </td>
                <td>
                </td>
                <td>
                </td>
                </td>
                <td>
                </td>
                <td>
                </td>
                <td>
                    <label>
                        <div><h2>爬取网页页数</h2></div>
                    </label>
                    <label>
                        <div>&nbsp</div>
                    </label>
                    <div>
                        <label>
                            <input type="text" name="total" placeholder="爬取网站页数" >
                        </label>
                    </div>
                </td>
				<td>
				</td>
                <td>
				</td>
				<td>
				</td>
                <td>
				</td>
				</td>
				<td>
				</td>
                <td>
				</td>
				</td>
				<td>
				</td>
                <td>
				</td>
				</td>
				<td>
				</td>
                <td>
				</td>
                <td>
                </td>
				</td>
				<td>
				</td>
                <td>
				</td>
				<td>
				</td>
                <td>
				</td>
				</td>
				<td>
				</td>
                <td>
				</td>
				</td>
				<td>
				</td>
                <td>
				</td>
				</td>
				<td>
				</td>
                <td>
				</td>
                <td>

                    <div>
                        <label>
                            <h3><br><br>&nbsp;性能有限，爬取数量过多<br>可能需要等待1-3分钟<br></h3>
                        </label>
                    </div>
                    <div>
                        <label>
                            <button class="button"  type="submit" onclick="javascript:return validateForm();">开始爬取</button>
                            <button class="button"  type="submit" formaction="spider?code=3">查看上次</button>
                        </label>
                    </div>
                </td>
            </table>
        
        </form>
    </div>
    </div>
  </div>
  <div class="rightcolumn">
    <div class="card">
      <h2>关于我们团队</h2>
      <div class="fakeimg" style="height:100px;"><p>图片</p></div>
      <p>关于我的一些信息..</p>
    </div>
    <div class="card">
      <h2>相关网站</h2>
      <h3><a href = "https://mkt.51job.com/tg/sem/LP_2020_1.html?from=baidupz">前程无忧网</a></h3>
	  <h3><a href = "https://www.qlrc.com/">齐鲁人才网</a></h3>
	  <h3><a href = "https://zhaopin.baidu.com/">猎聘网</a></h3>
    </div>
  </div>
</div>
<div class="footer">
  <h2>Design by TTXS</h2>
</div>
</body>
</html>